A contrast detection method (called a blur detection method) and a phase difference detection method (called a defocus detection method) have been proposed as general methods using a light beam having passed through an imaging optical system in automatic focus detection/adjustment of an image sensing apparatus.
The contrast detection method is often used in a video movie camera (camcorder) for recording a moving image, and an electronic still camera. The image sensor is used as a focus detection sensor. This method pays attention to the output signal of the image sensor, especially high-frequency component information (contrast information), and a position of the imaging optical system where the evaluation value maximizes is set as an in-focus position. However, this contrast detection method, also called a hill-climbing detection method, is not suitable for a high-speed focus adjustment operation because the evaluation value is obtained while slightly moving the imaging optical system, and the imaging optical system needs to be moved until it is determined that the evaluation value was maximum.
The phase difference detection method is generally adopted in single-lens reflex cameras using a silver halide film, and is a technique most contributed to practical use of AF (Auto Focus) single-lens reflex cameras. According to the phase difference detection method, a light beam having passed through the exit pupil of the imaging optical system is split into two, and the two light beams are received by a pair of focus detection sensors. The defocus amount of the imaging optical system in the focusing direction is directly obtained by detecting the difference between signals output in accordance with the light reception amounts, that is, the relative positional error amount in the direction in which the light beam is split. Once the focus detection sensor executes the accumulation operation, the defocus amount and direction can be attained to perform a high-speed focus adjustment operation. To split a light beam having passed through the exit pupil of the imaging optical system into two, and obtain signals corresponding to the two light beams, an optical path division means such as a quick return mirror or half-mirror is generally inserted in the image sensing optical path, and a focus detection optical system and AF sensor are arranged on the output side of the optical path division means. This structure makes the device bulky and expensive.
To solve this problem, there is also disclosed a technique of adding a phase difference detection function to an image sensor to eliminate a dedicated AF sensor and implement high-speed phase difference AF.
For example, in Japanese Patent Laid-Open No. 2000-156823, the pupil division function is added to some light receiving elements (pixels) of an image sensor by decentering the sensitive areas of their light receiving portions from the optical axis of an on-chip microlens. These pixels are used as focus detection pixels, and arranged between image sensing pixels at predetermined intervals to perform phase difference focus detection. Since no image sensing pixel exists at portions where focus detection pixels are arranged, image information is generated by interpolation using information from peripheral image sensing pixels.
In Japanese Patent Laid-Open No. 2000-292686, the pupil division function is implemented by dividing each of the light receiving portions of some pixels of an image sensor into two, right and left, or upper and lower portions. These pixels are used as focus detection pixels, and arranged between image sensing pixels at predetermined intervals to perform phase difference focus detection. According to this technique as well, no image sensing pixel exists at portions where focus detection pixels are arranged, so image information is generated by interpolation using information from peripheral image sensing pixels.
In Japanese Patent Laid-Open No. 2001-305415, the pupil division function is provided by dividing each of the light receiving portions of some pixels of an image sensor into two, upper and lower portions. Outputs from the two divided light receiving portions are individually processed to execute phase difference focus detection for an object having a luminance distribution in the vertical direction. Outputs from the two divided light receiving portions are added and used as an image sensing signal. Further, the contrast between pixels adjacent to each other in the horizontal direction is detected to perform contrast focus detection for an object having a luminance distribution in the horizontal direction.
In Japanese Patent Laid-Open No. 2003-153291, focus detection elements whose light receiving portions are divided into right and left, or upper and lower portions are repetitively arranged every other line of an image sensor. With this arrangement, phase difference focus detection is done for an object having luminance distributions in the horizontal and vertical directions.
Items which should be considered when executing phase difference detection AF using an image sensor will be listed below. As for the AF performance, the following items need to be satisfied.
(a) Focus can be detected regardless of the direction of the luminance distribution of an object. In other words, the focus can be detected along vertical, horizontal, and oblique lines.
(b) Focus detection image sampling error is very small, and the focus detection precision is independent of the spatial frequency and phase of an object.
(c) Focus can be detected in an arbitrary area.
(d) The S/N ratio of a focus detection image signal is high even for a low-brightness object, and the focus detection precision does not decrease.
(e) The arrangement coordinates of focus detection pixels are regular, and the algorithms of focus detection pixel signal processing and focus detection calculation are simple.
When generating an output image, focus detection pixels function as singular or defective pixels. To prevent degradation of an output image, the following items need to be satisfied.
(i) The ratio of the number of focus detection pixels to the total number of pixels of an image sensor is low.
(ii) Focus detection pixels are distributed uniformly.
(iii) The arrangement coordinates of focus detection pixels are regular, and the defective pixel interpolation algorithm is simple.
An increase in focus detection precision and prevention of degradation of an output image generally have a trade-off relationship. An advanced technique is required to satisfy all the listed items while balancing them. However, the above-mentioned conventional techniques suffer the following disadvantages.
The technique disclosed in Japanese Patent Laid-Open No. 2000-156823 cannot meet items (a), (c), and (ii) because focus detection pixels for dividing the pupil in one direction are locally and densely arranged.
The technique disclosed in Japanese Patent Laid-Open No. 2000-292686 cannot meet items (c) and (ii) because focus detection pixels for dividing the pupil in the horizontal or vertical direction are densely arranged in a specific focus detection area.
The technique disclosed in Japanese Patent Laid-Open No. 2001-305415 cannot meet item (i) because phase difference focus detection pixels are densely arranged. In addition, this technique does not sufficiently meet item (a) because focus detection in one direction is contrast detection and the focus detection capability is poor for an object having a luminance distribution in only this direction.
The technique disclosed in Japanese Patent Laid-Open No. 2003-153291 cannot meet item (i) because focus detection pixels are arranged every other line and the arrangement density is very high. It is, therefore, difficult to obtain a high-quality image.